Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

PortalWebHosting
  Ads  
Biz Modules provides professional business modules and solutions for DotNetNuke
 


  Sponsors  

Meet Our Sponsors

Webhost4life, specialists in DNN hosting
Mad Development is a full service interactive agency focusing on the merge of design, technology, e-commerce, and affiliate marketing by providing total website solutions.
AspDotNetStoreFront - E-Commerce by Design - The Leading ASP.NET shopping cart platform for developers!
SteadyRain
DataSprings - Great Ideas. Always Flowing.
R2integrated - formerly bi4ce
 


DotNetNuke Forums
 
  Forum  DotNetNuke® Pro...  User Defined Ta...  SQL statement to get the records added by a certain user on a UDT
Previous Previous
 
Next Next
New Post 6/4/2008 5:18 PM
Resolved
User is offline egraells
28 posts
10th Ranked


SQL statement to get the records added by a certain user on a UDT 

Hi, I'm developing a custom module that should show the records added by the user on a UDT on the site. So far I've checked the UserDefined* tables by I can't see how to get the rows.

So, users are adding rows to the wishes UDT, and I need to show on my module only the rows added on that Wishes UDT by the logged user.

Could anybody help?

Thanks in advance,

Esteve.


ege
 
New Post 6/5/2008 3:10 AM
User is offline Sebastian Leupold
15057 posts
www.deutschnetnuke.de
1st Ranked












Re: SQL statement to get the records added by a certain user on a UDT 

UDT rows are stored serialized:

  • usedefinedfields contains field definition
  • userdefinedrows holds the row ID
  • userdefineddata stores in each record a single value per field*row.

Sebastian Leupold

DeutschNetNuke dnnWerk - The DotNetNuke Experts German DotNetNuke User-Group

DotNetNuke Project UserDefinedTable
DotNetNuke Project Release Tracker
 
New Post 6/5/2008 3:36 AM
User is offline Stefan Cullmann
1553 posts
5th Ranked








Re: SQL statement to get the records added by a certain user on a UDT 
Modified By Stefan Cullmann  on 6/5/2008 5:37:41 AM)

I really recommend to use the UDT API:

Dim udt As UserDefinedTableController
Dim ds As DataSet = udt.GetDataSet(moduleid)

'Look Up the title of the "Created by Column
Dim dv As New DataView(ds.Tables(1), _
   String.format("[{0}]='{1}'", "FieldType", "CreatedBy"), "", DataViewRowState.CurrentRows)
Dim titleOfCreatedByColumn = dv.Item(0)("FieldTitle")

'Filter Data
dv = New DataView(ds.Tables(0), _
            String.format("[{0}_UDT_Original] = '{1}'", titleOfCreatedByColumn, Me.UserInfo.Username), _
            "", DataViewRowState.CurrentRows)

Stefan Cullmann - stefan.cullmann [at] dotnetnuke.com
form and List will be the successor of the User Defined Table module.
----------------------------------------------------------------------
Do you want to import external data to form and List /User Defined Table?
Check out http://www.codeplex.com/Csv2UDTImport
 
New Post 6/5/2008 9:48 AM
User is offline egraells
28 posts
10th Ranked


Re: SQL statement to get the records added by a certain user on a UDT 

Thank so much Stefan. Just one more question, and sorry to be a nuisance, where can I find the complete API for the UDT? I've checked the downloadables files after reading your post, but I couldn't find them.

Best Regards,
Esteve.


ege
 
New Post 6/5/2008 11:13 AM
Accepted Answer 
User is offline Sebastian Leupold
15057 posts
www.deutschnetnuke.de
1st Ranked












Re: SQL statement to get the records added by a certain user on a UDT 

Esteve,

API is part of the source code, you can download and install in any DNN 3.3.5-3.3.7 installation. Another option is using class browser in VS or Reflector.


Sebastian Leupold

DeutschNetNuke dnnWerk - The DotNetNuke Experts German DotNetNuke User-Group

DotNetNuke Project UserDefinedTable
DotNetNuke Project Release Tracker
 
Previous Previous
 
Next Next
  Forum  DotNetNuke® Pro...  User Defined Ta...  SQL statement to get the records added by a certain user on a UDT
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, 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 DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


DNN Photo Gallery
Complete Photo Gallery Management!
www.dnnPhotoGallery.com
R2i - Delivering Serious DNN Services & Solutions
Award Winning Design, Skin construction, Custom Modules and Consulting Services for the Enterprise organization. R2i is the DNN:Map module Project Lead and one of the largest DNN service providers with offices in New York City, Virginia and Baltimore.
www.bi4ce.com
"SalarO" Skinning Graphic Design Branding Services
SalarO develops packaged & custom skins for your DNN at prices you can afford. SalarO is also developing Module development, Hosting, Branding/Logo design as well as Content Transfer Services to complement the core skinning solutions.
www.salaro.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP