Here it is. No one has yet to tell me why it's too long. It was created in the View Designer. Also, do you know how to execute a SELECT statement and display the results in a grid? I've tried doing the SELECT INTO a CURSOR, but the grid doesn't show - not even the headers. If I can't use the View Designer, I'll have to simulate what I need to do in code.
SELECT DISTINCT Buildings.name, Buildings.address,;
Buildings.postalcode, Buildings.built, Buildings.floors,;
Buildings.location, Buildings.class, Buildings.type, Buildings.totsqfeet,;
Buildings.totavail, Buildings.larconspac, Buildings.rental1,;
Buildings.rental2, Buildings.consttype, Buildings.comments,;
Buildings.city, Buildings.state, Buildings.lpmcoid, Buildings.buildcoid,;
Buildings.loaddoors, Buildings.railserv, Buildings.sprinkler,;
Buildings.clearhgt, Buildings.janitorial, Buildings.utilities,;
Buildings.webaddress;
FROM cpi!agents INNER JOIN cpi!buildings ;
ON Agents.contactid = Buildings.lpmcoid;
WHERE UPPER(Buildings.name) LIKE UPPER(?bname);
AND UPPER(Buildings.address) LIKE UPPER(?baddress);
AND UPPER(Buildings.city) LIKE UPPER(?bcity);
AND UPPER(Buildings.state) LIKE UPPER(?bstate);
AND UPPER(Buildings.postalcode) LIKE UPPER(?bpostalcode);
AND UPPER(Buildings.built) LIKE UPPER(?bbuilt);
AND UPPER(Buildings.lpmcoid) LIKE UPPER(?blpmcoid);
AND Buildings.floors = ?bfloors;
AND UPPER(Buildings.location) LIKE UPPER(?blocation);
AND UPPER(Buildings.class) LIKE UPPER(?bclass);
AND UPPER(Buildings.type) LIKE UPPER(?btype);
AND Buildings.totsqfeet = ?btotsqfeet;
AND Buildings.totavail = ?btotavail;
AND Buildings.larconspac = ?blarconspac;
AND UPPER(Buildings.rental1) LIKE UPPER(?brental1);
AND UPPER(Buildings.rental2) LIKE UPPER(?brental2);
AND UPPER(Buildings.consttype) LIKE UPPER(?bconsttype);
AND UPPER(Buildings.comments) LIKE UPPER(?bcomments);
AND UPPER(Buildings.buildcoid) LIKE UPPER(?bbuildcoid);
AND UPPER(Buildings.loaddoors) LIKE UPPER(?bloaddoors);
AND Buildings.railserv = ?brailserv;
AND Buildings.sprinkler = ?bsprinkler;
AND UPPER(Buildings.clearhgt) LIKE UPPER(?bclearhgt);
AND Buildings.janitorial = ?bjanitorial;
AND Buildings.utilities = ?butilities;
ORDER BY Buildings.name
Let me know your ideas on this one.
Thanks.
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only