Solved

Need Uppercase Update functionality from PB

Posted on 2000-04-13
5
766 Views
Last Modified: 2008-02-20
I have a PowerBuilder application that I need to run against a Sybase ASE 12 database which is configured to be case sensitive and requires all SQL to be uppercase.  I converted all of the datawindow retrieve and embedded SQL to uppercase and it all works, but the datawindow updates did not work.  I exported the datawindows and changed all of the update DB names to uppercase but it still is working for the updates.
Does anyone have any ideas of anything that I could try??
0
Comment
Question by:cwilliams122399
5 Comments
 
LVL 2

Expert Comment

by:jkotek
ID: 2712361
There are two points I would try:

1) try to re-select updatable table in update properties of datawindow object

2) check sqlsyntax argument in SQLPreview for what is send to ASE.
0
 
LVL 9

Expert Comment

by:david_levine
ID: 2714274
Or run your app with /PBDEBUG and it will output a debug file with all the code and sql sent to the database.

You saud all SQL needs to be uppercase. You shouldn't have to worry about the case of the SQL syntax. You meant the column names? Or do you mean you want to keep the data in all upper case?

David
0
 
LVL 1

Expert Comment

by:runebj
ID: 2725669
Quick and simple...

Follow jkotek's advice, but add this code (can be done in a DW control ancestor if you like) to the SQLPreview event:

SetSQLPreview( Upper( SQLSyntax ) )
Return 0

This makes all SQL uppercase before it is sent to the DB.

Good luck
Runebj
0
 

Expert Comment

by:shabbirab
ID: 2770528
Any modifications in a PB DataWindow (even if it is changing the case of the source) requires to re-specify the Update on the DataWindow. Did you do this ? If yes, what is the message that you are getting when you run the PB Application ?

Shabbir
0
 

Accepted Solution

by:
russ_hensel earned 350 total points
ID: 2847549
In the dw syntax there is a statement like  update="plant" ( in this case from a pbselect, or graphics mode ) it tells pb the name of the table to update.  That is what needs to be in upper case.
You can get at this without running thru the syntax of the dw ( not the sql )
by using the dw property


Datawindow.Table.UpdateTable      
as in

ls_table =  dw_1.Object.DataWindow.Table.UpdateTable      

which you might follow with

dw_1.Object.DataWindow.Table.UpdateTable      = Upper( ls_table )

if you want to do a fix at runtime. ( prehaps just after you setTransObject )

Opening the painter and reseting the update table ( against a db with the proper capitilization ) should also fix up the dw.

I would not capatalize all the syntax, if you are not using bind variables it could cause problems.

Russ
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
sybase, how do we check what privileges granted or cover by role ? 2 1,576
how to add a function to sybase 10 1,206
Visual Studio 2010 with SyBase 3 836
SyBase SQL Query 7 154
Microsoft Office Picture Manager was included in Office 2003, 2007, and 2010, but not in Office 2013. Users had hopes that it would be in Office 2016/Office 365, but it is not. Fortunately, the same zero-cost technique that works to install it with …
There is no doubt that cloud is gaining importance. Many of you must have read about this technology and its growing importance. More and more organisations are embracing this technology not forgetting start-ups. The process begins by dipping …
This tutorial gives a high-level tour of the interface of Marketo (a marketing automation tool to help businesses track and engage prospective customers and drive them to purchase). You will see the main areas including Marketing Activities, Design …
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now