java - Converting PBSELECT to standard SQL -
I'm trying to convert PowerBuilder stuff (containing PBSELECT statement) to Java. I am very comfortable with other things except PBSELECT statement within it.
I want to convert to standard SQL format under the PBLabel statement. Table (name = "table_barcode_attrib_map") table (name = "table_barcode_attribute") column (name = "table_barcode.label_name") of
PBSELECT (VERSION (400) TABLE name = "table_barcode") Calculation (name = "IsNull (table_barcode_attrib_map.value, 0) pacmed_valid") JOIN (Left = "table_barcode.barcode_id" OP = "=" true = "table_barcode_attrib_map.barcode_id" OUTER1 = "table_barcode.barcode_id") JOIN (Left = "Table_barcode_attrib_map.attribute_id "Op =" = "true =" table_barcode_attribute.attribute_id "OUTER1 =" table_barcode_attrib_map.attribute_id ") where (EXP1 =" (~~ "table_barcode ~~ barcode_id ~~" "OP =" = "EXP2 Where (EXP1 = "Table_barcode_attribute.attribute_name" OP = "=" EXP2 = "'PACMED Valid Flag'")) ARG (NAME = "as_barcode_id" TYPE) = "" ~~. ": As_barcode_id) = String)
withi N PBSELECT statement, I can not understand the JOIN clause with OUTER1 and earlier WHERE ~ ~ "pattern.
Please convert PBSELECT to standard SQL Help please Any help highly appreciated
I have seen people writing this conversion routine for graphical SQL encoding, but what I've heard From PowerBuilder engineering staff, it is not possible to correctly do the conversion database driver and receive specific specific information about the conversion from the connection parameters, so a conversion routine that works in a condition (like a database engine) Can not work in the other way.
As the comments (thanks!), My tool can help you need database connection parameters that use the application (search for code or INI files for features named DBMS), But after that, you can dump SQL to all data windows (report / datawindow SQL) or you can get it on one time (browse / RMB a DW object / object report / DataWind Do sql). This is a great way to browse around the code, especially if you do not have a PowerBuilder
BTW, if you are changing, keep this in mind:
- DataWindows
- DataWindow (SQL and many other properties of DataWindows) can be dynamically modified in run time through code < Li> In addition to SQL, many features (like X, Y, width, height ...) are non-static values Receiving from sources that can access PowerBuilder from run-time memory variables (such as a power script in variables), or any other values from the database (day of week, screen resolution, etc ...) < / Li>
- Many of the features are interdependent (like Y and SlideUp)
- DataWindows can be generated dynamically from scratch at run time, and that is generated by syntax code Can be done, or columns drawn from any source like files or databases (your list of datawindows from PowerBuilder libraries (PBLs) can not be a complete picture)
I Took large lists of more problems, do not underestimate your work by getting the idea.
Good luck,
Terry
Comments
Post a Comment