Re: Character variable problem in 4GL
Posted in 1993
A workaround might be to monitor the LENGTH() of the string as you are creating the CREATE TABLE string, and when it gets close issue the command to create the table, and then make subsequent ALTER TABLE calls to add the rest of the columns or constraints to complete the work. ================ Dennis J. Pimple Informix CSE / Denver gtm@mallard.UUCP (Madi) writes: >Hello, >I have a 4GL function which creates tables dynamically. I need to prepare >the "create table" statement. Since the table created will be huge >the char variable which holds the create statement has to be large enough >to hold the entire create statement. Unfortunately when i try to >declare a character variable (globally or locally) whose size is greater >than 32767 ,+1 for null (2^15) like >DEFINE cr_str char(32767) >the 'C' function generated by the c4gl has a definition >char cr_str[102]; >(Obviously the 4gl to C generator uses a short int) >Is there a way to overcome this without replacing the 4GL function >with a 'C' function (since the function is complicated,which is easy to >write in 4GL). >Thanks in advance. >+---------------------------+--------------------------+ >| G.T.Madavan, | e-mail: gtmad@smi.mn.org | >| Systems Migration Inc., | Phone : (612) 890-0040 | >| Burnsville, MN, U.S.A | Fax : (612) 890-0966 | >+--------------------------+---------------------------+ >~