Python Forum
Peewee returning objects and not strings..
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Peewee returning objects and not strings..
#2
You can use vars to see what the object data is.
class Data:
	def __init__(self):
		self.data = "line"
		self.data2 = "line2"
		
data = Data()
print(data)
print(vars(data))
99 percent of computer problems exists between chair and keyboard.
Reply


Messages In This Thread
RE: Peewee returning objects and not strings.. - by Windspar - Dec-10-2017, 04:49 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Create SQLite3 database with peewee Jim53_1980 2 739 Dec-20-2023, 02:38 PM
Last Post: buran
  Trying to understand strings and lists of strings Konstantin23 2 842 Aug-06-2023, 11:42 AM
Last Post: deanhystad
  Splitting strings in list of strings jesse68 3 1,839 Mar-02-2022, 05:15 PM
Last Post: DeaD_EyE
  Finding multiple strings between the two same strings Slither 1 2,569 Jun-05-2019, 09:02 PM
Last Post: Yoriz
  lists, strings, and byte strings Skaperen 2 4,284 Mar-02-2018, 02:12 AM
Last Post: Skaperen
  peewee.OperationalError: no such table: JerryMotov 3 7,103 Dec-10-2017, 05:45 PM
Last Post: JerryMotov

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020