Reviews examples of details on how to pass data to a stored procedure and how to return data from a stored procedure. Further shows how to pass status or debugging messages from stored procedure, including message localization.
More Stored Procedures and MUMPS for DivConqeTimeline, LLC
Reviews how Schema is used to define stored procedures and to validate the parameters during a call. Also, gives an example of updating the database from a stored procedure.
More Stored Procedures and MUMPS for DivConqeTimeline, LLC
Reviews how Schema is used to define stored procedures and to validate the parameters during a call. Also, gives an example of updating the database from a stored procedure.
We aren't sure about you, but working with Java 8 made one of the speakers lose all of his hair and the other lose his sleep (or was it the jetlag?). If you still haven't reached the level of Brian Goetz in mastering lambdas and strings, this talk is for you. And if you think you have, we have some bad news for you, you should attend as well.
If you saw the "Crusty Talk" (Protocol Oriented Programming in Swift) at WWDC, you saw Apple announce Swift as the first "Protocol Oriented language." If you immediately jumped into Xcode and tried to write a lot of protocol oriented code, you may have discovered that the promise isn't quite the reality. In this talk, you'll learn how to rethink your types so that you can avoid complex protocol problems without giving up their power.
Курс "Программирование на Java". Лекция 07 "Бонус - Головоломки".
Java Puzzlers. Синхронизация и многопоточность. Примитивы. Объекты и классы. Исключения и финализация.
МФТИ, 2016 год. Лектор - Лаврентьев Федор Сергеевич
Google Guava - Core libraries for Java & AndroidJordi Gerona
Talk at GDG DevFest Barcelona 2013.
The Guava project contains several of Google's core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth.
This session will take you on a tour of several languages that on the surface only share one thing in common – they all run on JVM as the execution platform. However, despite completely different appearances of Scala, Clojure, Jython and Groovy, we will demonstrate that they have some important commonalities. You will also see the emerging importance of JVM as a generic platform (as opposed to focusing on Java the language).
During the session we will implement a solution to a simple problem in each language, then compare these languages to Java. These solutions, while simple, will nonetheless highlight some of the common principles and implementation patterns that exist across the languages based on different paradigms. The solutions will also show how these approaches are different from implementation patterns common in Java.
We aren't sure about you, but working with Java 8 made one of the speakers lose all of his hair and the other lose his sleep (or was it the jetlag?). If you still haven't reached the level of Brian Goetz in mastering lambdas and strings, this talk is for you. And if you think you have, we have some bad news for you, you should attend as well.
If you saw the "Crusty Talk" (Protocol Oriented Programming in Swift) at WWDC, you saw Apple announce Swift as the first "Protocol Oriented language." If you immediately jumped into Xcode and tried to write a lot of protocol oriented code, you may have discovered that the promise isn't quite the reality. In this talk, you'll learn how to rethink your types so that you can avoid complex protocol problems without giving up their power.
Курс "Программирование на Java". Лекция 07 "Бонус - Головоломки".
Java Puzzlers. Синхронизация и многопоточность. Примитивы. Объекты и классы. Исключения и финализация.
МФТИ, 2016 год. Лектор - Лаврентьев Федор Сергеевич
Google Guava - Core libraries for Java & AndroidJordi Gerona
Talk at GDG DevFest Barcelona 2013.
The Guava project contains several of Google's core libraries that we rely on in our Java-based projects: collections, caching, primitives support, concurrency libraries, common annotations, string processing, I/O, and so forth.
This session will take you on a tour of several languages that on the surface only share one thing in common – they all run on JVM as the execution platform. However, despite completely different appearances of Scala, Clojure, Jython and Groovy, we will demonstrate that they have some important commonalities. You will also see the emerging importance of JVM as a generic platform (as opposed to focusing on Java the language).
During the session we will implement a solution to a simple problem in each language, then compare these languages to Java. These solutions, while simple, will nonetheless highlight some of the common principles and implementation patterns that exist across the languages based on different paradigms. The solutions will also show how these approaches are different from implementation patterns common in Java.
Slides from talk given at Ithaca Web Group and GORGES on CoffeeScript.
The focus is on explaining to people who haven't tried it yet that it's more than syntactic sugar. There are several real life code examples but they were explained verbally so they may not be super helpful if you don't know CoffeeScript yet.
It's an overview, not a tutorial.
Reason - introduction to language and its ecosystem | Łukasz StrączyńskiGrand Parade Poland
A moderately deep look at new language with OCaml roots. Is there a reason to be hyped about it? Is it mature enough to be considered production ready?
What does it offer over JS, Flow or other compiled to JS languages?
This presentation explains parameterized tests, theory tests, and generative testing. It also explains single mode faults and double mode faults and shows how to reduce the number of test cases when there's an combinatorial explosion. Lot's of JUnit examples.
A look at the future of JVM languages including Kotlin, Scala, Groovy, and latest Java.
Which language to use ? what are the benefits of higher level abstractions ? and what are the benefits of programming on the JVM ?
Game Design and Development Workshop Day 1Troy Miles
This course teaches you how to build awesome video games using Cocos2Dx. Cocos2Dx is a feature packed, free game development engine. It is cross platform, high performance, and supports three languages: C++, Lua and JavaScript. With it, you can write games for iOS, Android, Windows, Mac, and the Web. It is nothing short of amazing and this course teaches you how to use it. We will program Cocos2Dx in JavaScript, but this is not a programming class. If you don't know how to write code in JavaScript or some other curly brace language, this is not the course for you. For those whose JavaScript is rusty, we will do quick language overview. Don't let the JavaScript part fool you. Cocos2Dx is built from highly optimized C++ and OpenGL, JavaScript is used for game logic, not graphics. Our games will run at a super fast, 60 frames a second.
Although mobile applications have been around for several years, developing on Android is still challenging. In this talk, we will see how to write an Android application using clean architecture and TDD methodology, in order to write (almost) fully tested and easy to maintain applications.
The talk is meant to show how to write tests for the common task of loading and displaying an API to users. We’ll also discuss how to structure the code in order to avoid any dependency chaos and test every single component in isolation.
The talk will also make use of Kotlin: the first real alternative to Java within the Android world.
Slides for a lightning talk on Java 8 lambda expressions I gave at the Near Infinity (www.nearinfinity.com) 2013 spring conference.
The associated sample code is on GitHub at https://github.com/sleberknight/java8-lambda-samples
Testing and validating distributed systems with Apache Spark and Apache Beam ...Holden Karau
As distributed data parallel systems, like Spark, are used for more mission-critical tasks, it is important to have effective tools for testing and validation. This talk explores the general considerations and challenges of testing systems like Spark through spark-testing-base and other related libraries.
With over 40% of folks automatically deploying the results of their Spark jobs to production, testing is especially important. Many of the tools for working with big data systems (like notebooks) are great for exploratory work, and can give a false sense of security (as well as additional excuses not to test). This talk explores why testing these systems are hard, special considerations for simulating "bad" partioning, figuring out when your stream tests are stopped, and solutions to these challenges.
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Ramesh Iyer
In today's fast-changing business world, Companies that adapt and embrace new ideas often need help to keep up with the competition. However, fostering a culture of innovation takes much work. It takes vision, leadership and willingness to take risks in the right proportion. Sachin Dev Duggal, co-founder of Builder.ai, has perfected the art of this balance, creating a company culture where creativity and growth are nurtured at each stage.
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
3. About DivConq
http://www.divconq.com/about/
Getting Started With DivConq
http://www.divconq.com/home/getting-started/
This presentation is part of a sequence of presentations on DivConq’s database
features. Visit the Getting Started page at our website to see the suggested order
for our presentations.
5. In the previous presentations we focused on how stored procedures worked
within Java. Things like the request-response flow, request objects, callbacks,
schema and JSON-Like data structures.
In the coming slides the focus is going to be on MUMPS development for stored
procedures. We’ll use some examples that ship with DivConq Framework so you
can follow along.
6. D:devdivconqtemplate>.binrun.bat testdb
Command testdb
Starting Hub
...
You should recall how to run TestDb from previous presentations in Getting
Started. If not then you may wish to review those presentations.
7. Select option 4 “Load stored proc results (testProc1)”. The output we see will be
JSON, but keep in mind the database result uses DivConq’s Struct classes
(JSON-Like API). Your output should be:
testProc1 Response:
{
"Name": "Sally",
"Age": 5,
"Toys": [
"Legos",
"Puzzle"
] ,
"Friends": [
{
"Name": "Chad",
"Age": 5
} ,
{
"Name": "Ginger",
"Age": 6
}
]
}
9. testProc1 n data,tnum,fnum
;
s data("Name")="Sally"
s data("Age")=5
s data("Toys",1)="Legos"
s data("Toys",2)="Puzzle"
s data("Friends",1,"Name")="Chad"
s data("Friends",1,"Age")=5
s data("Friends",2,"Name")="Ginger"
s data("Friends",2,"Age")=6
;
[continued]
This first and simplest example starts by populating a local MUMPS data
structure.
10. [continued]
w StartRec
w Field_"Name"_ScalarStr_data("Name")
w Field_"Age"_ScalarInt_data("Age")
;
w Field_"Toys"_StartList
f s tnum=$o(data("Toys",tnum)) q:tnum="" d
. w ScalarStr_data("Toys",tnum)
w EndList
;
[continued]
Java output from this part:
{ "Name": "Sally", "Age": 5, "Toys": [ "Legos", "Puzzle" ] ,
Then the result is started by using MUMPS’ “write” commands. The start of a
record or list begins with StartRec or StartList. The start of a field name starts
with Field. The start of a field value or item is always ScalarNNN.
11. [continued]
w Field_"Friends"_StartList
f s fnum=$o(data("Friends",fnum)) q:fnum="" d
. w StartRec
. w Field_"Name"_ScalarStr_data("Friends",fnum,"Name")
. w Field_"Age"_ScalarInt_data("Friends",fnum,"Age")
. w EndRec
w EndList
[continued]
Java output from this part:
"Friends": [ { "Name": "Chad", "Age": 5 } ,
{ "Name": "Ginger", "Age": 6 } ]
“Friends” is a field. The field value is a list of records where each record has two
fields. Note how EndRecord and EndList are paired, you must have an EndNNN
for every StartNNN. Field and ScalarNNN do not need an ending delineator.
12. [continued]
;
w EndRec
;
quit
Java output from this part:
}
Stored procedures will always return a record or a list. So the last “write”
command in a stored proc should always be EndRec or EndList – to match the
first write.
13. $ sudo su gtmuser
$ cd ~
$ ./gtmcon
GTM>d local^dcConn("QUERY testProc1")
Data:
{ , Name: Sally, Age: 5, Toys[ : Legos: Puzzle] , Friends[ { ,
Name: Chad, Age: 5} { , Name: Ginger, Age: 6} ] } !
Messages:
[ ] !
Stored procedures are used by Java, but if you want to test your procedure in
MUMPS you may emulate a Java call. Bring up the MUMPS prompt, something
like above, and then call local^dcConn to run the procedure. When calling
procedures this way you’ll want to use “UPDATE” or “QUERY” – only use
“UPDATE” if the call will change data in the database.
14. { , Name: Sally, Age: 5, Toys[ : Legos: Puzzle] , Friends[ { ,
Name: Chad, Age: 5} { , Name: Ginger, Age: 6} ] } !
The results returned to Java from stored procedures are not in JSON format.
Likewise, when we run the procedure within MUMPS we aren’t getting pure JSON
but we do get something similar.
Once you get used to ", " preceding every field (e.g. “, Name” and ": " preceding
every scalar (e.g. “: Legos”) then it is not too bad to read.
15. QueryRequest tp1 = new QueryRequest("testProc1");
ObjectCallback callback = new ObjectCallback() {
@Override
public void process(ObjectResult res) {
if (res.hasErrors()) {
System.out.println(" Error:");
TestDb.printPretty(res.getMessages());
}
else {
System.out.println(" Response:");
TestDb.printPretty(res.getResult());
}
}
};
Hub.instance.getDatabase().submit(tp1, callback);
A quick look back at how to call from Java, note the “Query” in QueryRequest and
the use of the name “testProc1”. Also note no parameters are used.
16. GTM>s Params(0)="gun"
GTM>s Params(1)="candy"
GTM>d local^dcConn("QUERY testProc2")
Data:
!
Messages:
[ { , Level: Error, Code: 1, Message: Gun not allowed in toy list}
{ , Level: Error, Code: 1, Message: Candy not allowed in toy list}
] !
Lets run the next test procedure, testProc2. This one will show us how to return
messages from a stored proc. Messages are not result data, but rather
information for tracing, info, warnings or errors. Only a few messages should be
returned from a procedure, do not try to return hundreds or more. Note you can
add a message anytime during the output generation – in the middle of a Field is
fine. Also we see how to pass Params from the M command line.
17. testProc2 n tnum,toy
;
; validate your inputs, if toy list is not there do not continue
i $d(Params)<10 d errMsg^dcConn("Missing toy list") quit
;
; continue input validation, check for undesirable toys
f s tnum=$o(Params(tnum)) q:tnum="" d
. s toy=Params(tnum)
. s toy=$$toUpper^dcStrUtil(toy)
. i toy["GUN" d errMsg^dcConn("Gun not allowed in toy list") q
. i toy["CANDY" d errMsg^dcConn("Candy not allowed in toy list") q
. i toy["HAMMER" d warnMsg^dcConn("A hammer may not be safe for this age") q
We expect a list of toys for our parameters. A check with $d tells us if the list is
missing. If so, then we need to add an error message and quit the routine.
Calling errMsg or warnMsg in dcConn is one way to do this, we’ll see another way
soon. Note that it is ok to “quit” before any output if there is an error. In Java
always check for errors in the result (ObjectResult) before processing the data.
Ignore the result data if an error occurred.
18. testProc2 n tnum,toy
;
; validate your inputs, if toy list is not there do not continue
i $d(Params)<10 d errMsg^dcConn("Missing toy list") quit
;
; continue input validation, check for undesirable toys
f s tnum=$o(Params(tnum)) q:tnum="" d
. s toy=Params(tnum)
. s toy=$$toUpper^dcStrUtil(toy)
. i toy["GUN" d errMsg^dcConn("Gun not allowed in toy list") q
. i toy["CANDY" d errMsg^dcConn("Candy not allowed in toy list") q
. i toy["HAMMER" d warnMsg^dcConn("A hammer may not be safe for this age") q
Loop the list of toys in our parameters. Check if the toy matches some key word,
if so create an error and continue in the loop. Every toy that fails will generate a
message. This should be capped, do not return more than a hundred messages
this way.
19. i Errors quit
;
; if only warnings or no validation messages then proceed
w StartList
f s tnum=$o(Params(tnum)) q:tnum="" d
. s toy=Params(tnum)
. s toy=$$toUpper^dcStrUtil(toy)
. w ScalarStr_toy
w EndList
;
quit
Before we do the output, which just echoes the list back, first check for any error
messages. Remember the validation loops all toys and may generate one or
more warning or error. Doing “i Errors quit” ensures that we don’t bother with
output if an error was created in a previous step.
20. ListStruct toys = new ListStruct("gun", "candy");
QueryRequest tp2 = new QueryRequest("testProc2", toys);
... Submit ...
// in your callback be sure to check for errors
if (res.hasErrors()) {
System.out.println(" Error:");
TestDb.printPretty(res.getMessages());
}
A glance back at calls from Java. Note passing the List of toys as parameters.
22. DivConq Name MUMPS Write Type
String ScalarStr
Integer ScalarInt
BigInteger ScalarBigInt
Decimal ScalarDec
BigDecimal ScalarBigDec
Boolean ScalarFalse, ScalarTrue or ScalarBool_”true|false”
Null ScalarNull
Binary ScalarBin
DateTime ScalarDateTime
BigDateTime ScalarBigDateTime
Above is a list of most the ScalarNNN types as they relate to the types in
Schema/Java. To refresh yourself on the data types, see the “Data Types in
DivConq” presentation.
23. Java
ListStruct toys = new ListStruct("gun", "candy");
// as used with
QueryRequest tp2 = new QueryRequest("testProc2", toys);
MUMPS
Params(0)="gun"
Params(1)="candy"
Lists in Java become numerical keys in MUMPS, starting at 0.
24. Java
RecordStruct params = new RecordStruct(
new FieldStruct("MinAge", 30),
new FieldStruct("MaxAge", 48)
);
MUMPS
Params("MinAge")=30
Params("MaxAge")=48
Records in Java become keyed by field name in MUMPS.
25. Java
ListStruct toys = new ListStruct(
new RecordStruct(
new FieldStruct("Name", "Mike"),
new FieldStruct("Age", 44)
),
new RecordStruct(
new FieldStruct("Name", "Mary"),
new FieldStruct("Age", 38)
)
);
MUMPS
Params(0,"Name")="Mike"
Params(0,"Age")=44
Params(1,"Name")="Mary"
Params(1,"Age")=38
Lists of Records become numerical keys with field name sub-keys.
26. Java
RecordStruct params = new RecordStruct(
new FieldStruct("Name", "Mike"),
new FieldStruct("Age", 14),
new FieldStruct(“Toys",
new ListStruct( "Bike", "Soccer Ball" )
)
);
MUMPS
Params("Name")="Mike"
Params("Age")=14
Params("Toys",0)="Bike"
Params("Toys",1)="Soccer Ball"
Records with lists become field name keys with numerical sub-keys.
27. Java
RecordStruct params = new RecordStruct(
new FieldStruct("Name", "Mike Jr."),
new FieldStruct("Age", 14),
new FieldStruct("Dad",
new RecordStruct(
new FieldStruct("Name", "Mike Sr."),
new FieldStruct("Age", 44)
)
)
);
MUMPS
Params("Name")="Mike Jr."
Params("Age")=14
Params("Dad","Name")="Bike Sr."
Params("Dad","Age")=44
28. Java
ListStruct params = new ListStruct(
new ListStruct( "Bike", "Soccer Ball" ),
new ListStruct( "Bat", "Soft Ball" )
);
MUMPS
Params(0,0)="Bike"
Params(0,1)="Soccer Ball"
Params(1,0)="Bat"
Params(1,1)="Soft Ball"
29. MUMPS has some limits to how big your keys and your values can get, but within
reason you can send very complex JSON-Like structures. There is more than
just the examples above. You can have a list of records that have fields with lists
of records.
Params([numerical],[field name],[numerical],[field name])=NNN
Or any combination of lists and records as long as it follows MUMPS limitations
(or specifically GT.M’s limitations – though if you used DivConq with Cache you’d
have to watch the limitations for Cache).
31. testProc3 n tnum,toy,utoy
;
; validate your inputs, if toy list is not there do not continue
i $d(Params)<10 d err^dcConn(90000) quit
;
; continue input validation, check for undesirable toys
f s tnum=$o(Params(tnum)) q:tnum="" d
. s toy=Params(tnum)
. s utoy=$$toUpper^dcStrUtil(toy)
. i (utoy["GUN")!(utoy["CANDY") d err^dcConn(90001,toy) q
. i utoy["HAMMER" d warn^dcConn(90002,toy) q
;
i Errors quit
...
The preferred way to send a message is to use a message code. Message
codes can be used to translate a message to the user’s locale. Note the calls to
“err” and “warn” in dcConn. Pass the code and, optionally, up to 6 parameters.
There is also an “info” and a “trace” function. For now you may use the 80,000 –
89,999 code range in your projects.
32. D:devdivconqtemplatepackagesdcTestalldictionarydictionary.xml
D:devdivconqtemplatepackagesdcTestalldictionaryx-pig-latin.xml
Every DivConq package should have a dictionary file (or many). The name of the
file doesn’t matter, though we can see that one file in dcTest contains Pig Latin.
What does matter is that you have an entry for every code in every supported
language.
33. <Dictionary>
<Locale Id="en">
<Entry Token="_code_90000" Value="Missing toy list" />
<Entry Token="_code_90001" Value="Toy not allowed: {$1}" />
<Entry Token="_code_90002" Value="Toy may not be safe: {$1}" />
<Entry Token="_code_90010" Value="Missing required fields" />
</Locale>
</Dictionary>
The first file contains only English (see Id attribute of Locale element). In
testProc3 the call to “d err^dcConn(90000)” produces “Missing toy list” when
using the English locale.
The call to “d warn^dcConn(90002,toy)” on the other hand has a parameter, the
toy’s name. The first parameter replaces {$1} in the message, so for a Hammer
the message becomes “Toy may not be safe: Hammer”.
34. <Dictionary>
<Locale Id="x-pig-latin">
<Entry Token="_code_90000" Value="Issingmay oytay istlay" />
<Entry Token="_code_90001" Value="Oytay otnay allowedway: {$1}" />
<Entry Token="_code_90002" Value="Oytay aymay otnay ebay afesay: {$1}" />
<Entry Token="_code_90010" Value="Issingmay equiredray ieldsfay" />
</Locale>
</Dictionary>
The second file contains only Pig Latin, though technically both translations could
be in the same file. The call to “d err^dcConn(90000)” produces “Issingmay oytay
istlay” when using the Pig Latin locale.
The call to “d warn^dcConn(90002,toy)” with a Hammer produces “Oytay aymay
otnay ebay afesay: Hammer”.
35. We now have a better idea of how to pass data to a stored procedure and how to
return data from a stored procedure. We also learned that we can pass status or
debugging messages from our stored procedure – and that those messages can
be localized.