Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsForm and ListForm and List2 Questions - Creating new Colum + Colum Lifetime2 Questions - Creating new Colum + Colum Lifetime
Previous
 
Next
New Post
7/30/2007 10:47 AM
 

Hello at first,

I have the problem that if i create a new colum in my existing table all existing rows have no value in this one. Is there an Option to refresh the table so all rows get the Default value of the new colum ?? Because i have bout 150-200 rows and it would make me a bit crazy pressing on every row edit -> save to get the default value into it.

And the second thing is, is there a possibility to set a so to speak "life time" for colums which would make them visible for a specified amount of time. F.e. i have a table which represents a calendar. (My colums are my dates) And i want to see only the last week, the actual week and maybe 1-2 weeks in the future. All the rest should already be in the table but not visible for the normaly registred users. So they always have the actual table visible if they log in.

p.s. sorry for my bad english ,)

 
New Post
7/30/2007 11:22 AM
 

regarding your first question, there is currently no option, the only idea I have is to create an update query, you can run from inside the host :: SQL menu item

regarding lifetime of rows there will be a filter option in the upcoming module version 3.4.0, that allows you to suppress specific entries.

 


Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
7/30/2007 4:08 PM
 

big thx for the fast answer! :)

but because im db newb i have to ask what specialy you meant with update query. Must i go into options of my sql 2005 express and switch there something in my dnn db or must i go trough the host options in my dnn portal and change there something in the sql code option ?

 
New Post
7/31/2007 9:55 AM
 

go to SQL in host menu and run the following query to fill all missing default values in all UDT instances:

INSERT INTO {databaseOwner}{objectQualifier}UserDefinedData (UserDefinedFieldId, UserDefinedRowId, FieldValue)
SELECT F.UserDefinedFieldId, R.UserDefinedRowId, [Default]
FROM ({databaseOwner}{objectQualifier}dnn_UserDefinedFields F
      INNER JOIN {databaseOwner}{objectQualifier}dnn_UserDefinedRows R ON F.ModuleId = R.ModuleId)
LEFT JOIN {databaseOwner}{objectQualifier}dnn_UserDefinedData D ON F.UserDefinedFieldId = D.UserDefinedFieldId AND R.UserDefinedRowId = D.UserDefinedRowId
WHERE D.UserDefinedRowID Is Null AND [Default] IS Not Null

Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
8/3/2007 9:41 AM
 

I tried it to input directly in the dnn host -> sql option and got this error ... :> i actualy did not watchtrough the whole thing but ill do now, just wanted to post it already if i cant find a way out of this problem...

 

System.Data.SqlClient.SqlException: Ungültiger Objektname 'dbo.dnn_UserDefinedFields'. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async) at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL) at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions) INSERT INTO dbo.UserDefinedData (UserDefinedFieldId, UserDefinedRowId, FieldValue) SELECT F.UserDefinedFieldId, R.UserDefinedRowId, [Default] FROM (dbo.dnn_UserDefinedFields F INNER JOIN dbo.dnn_UserDefinedRows R ON F.ModuleId = R.ModuleId) LEFT JOIN dbo.dnn_UserDefinedData D ON F.UserDefinedFieldId = D.UserDefinedFieldId AND R.UserDefinedRowId = D.UserDefinedRowId WHERE D.UserDefinedRowID Is Null AND [Default] IS Not Null

 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsForm and ListForm and List2 Questions - Creating new Colum + Colum Lifetime2 Questions - Creating new Colum + Colum Lifetime


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out