Memo field in ASP

Results 1 to 4 of 4

Thread: Memo field in ASP

  1. #1
    Michael Sharpe Guest

    Default Memo field in ASP

    In my asp page, I am trying to get the data out of a memo field to appear. I get all other types of data to appear except for the memo field. Is there something that I have to do to get this to work?

  2. #2
    Join Date
    Dec 1969

    Default RE: Memo field in ASP

    Use textarea tags like this:<BR>&#060;td&#062;&#060;textarea name="myname" rows="6" cols="40" wrap="virtual"&#062;&#060;%=recobj("myfield")%&#06 2;&#060;/textarea&#062;&#060;/td&#062;

  3. #3
    Join Date
    Dec 1969

    Default RE: Memo field in ASP

    there is a little bit more to it than that.<BR><BR>structure your SQL SELECT statement such that all fields are named explicitly, SQL Server Text and Access Memo fields are asked for last, and are ased for in the order they appear in the tables underlying the recordset.<BR><BR>let&#039s say we&#039re querying a table with the following structure:<BR><BR>MyTable<BR><BR>Field1<BR>Name: ID<BR>Access DataType: AutoNumber<BR>SQLServer DataType: int<BR><BR>Field2<BR>Name: First_Name<BR>Access DataType: Text<BR>SQLServer DataType: Char<BR><BR>Field3<BR>Name: Comments<BR>Access DataType: Memo<BR>SQLServer DataType: Text<BR><BR>Field1<BR>Name: Comments2<BR>Access DataType: Memo<BR>SQLServer DataType: Text<BR><BR>now, if we wish to write a SELECT query against this table and return all fields, it should look like this:<BR><BR>SELECT ID, First_Name, Comments, Comments2 FROM MyTable<BR><BR>the important things are that:<BR>a. the Memo fields are at the _end_ of the field list in the SQL statement<BR>and<BR>b. the Memo fields are included in the SQL statement in the same order in which they appear in the underlying table<BR><BR>good luck<BR><BR>kurt

  4. #4
    Michael Swanson Guest

    Default RE: Memo field in ASP

    Kurt gives the right answer, but I&#039d like to add one tip.<BR><BR>I usually grab the memo fields right away and store them in a variable if I need to reference them more than once.<BR><BR>Michael Swanson, MCSE, MCP+Internet<BR>Webmaster<BR>Donnelly Corporation<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts